﻿using SalesSys.DAL.Base;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Security.AccessControl;
using System.Text;
using System.Threading.Tasks;

namespace SalesSys.DAL.Models
{
    /// <summary>
    /// 客户联系人表
    /// </summary>
    public class CustomerContact : DbEntityBase<Guid>
    {
      
      /// <summary>
      /// 客户
      /// </summary>
      public virtual Customer Customer { get; set; }

      /// <summary>
      /// 客户编号
      /// </summary>
      public Guid CustomerId { get; set; }
      /// <summary>
      /// 联系人名称
      /// </summary>
      public string ContactUser { get; set; }
      /// <summary>
      /// 联系人职务
      /// </summary>
      public string ContactPosition { get; set; }
      /// <summary>
      /// 联系人电话
      /// </summary>
      public string ContactPhone { get; set; }
     
      /// <summary>
      /// 是否删除
      /// </summary>
      public bool IsDel { get; set; }
      /// <summary>
      /// 备注
      /// </summary>
      public string Remark { get; set; }
      public class Mapper : SalMapper<CustomerContact, Guid>
      {
          public Mapper()
          {
              HasRequired(p => p.Customer);
              Property(p => p.ContactUser);
              Property(p => p.ContactPosition);
              Property(p => p.ContactPhone);
              Property(p => p.IsDel);
              //Property(p => p.Remark);
          }
      }

    }
}
